package com.shujia.wyh.day06.homework.test6;

public class FamilyCar extends Car{
    private String userName;

    public FamilyCar() {
    }

    public FamilyCar(String carName, String carCard, String userName) {
        super(carName, carCard);
        this.userName = userName;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }


    @Override
    public void start() {
        System.out.println("我是"+userName+"，我的汽车我做主");
    }

    @Override
    public void stop() {
        System.out.println("目的地到了，我们去玩吧");
    }
}
